Repository navigation
Package the ground station for release: Windows and macOS bundles, release workflow - #61
yassinsolim wants to merge 6 commits into
Conversation
test_macos_app.py was linted by ament but never registered with colcon, so CI never ran it. It passes in the CI image, so register it like the other bringup tests.
In a release bundle the folder holds its own Python and compose.release.yaml, which runs the tested image by digest, so the script now: - prefers python\python.exe beside it to a Python on the PATH; - runs `docker compose -f compose.release.yaml run` with no --build, and pulls the image first with a message that says what to do if it is unauthorized; - takes -SelfTest, which checks Docker, Python, pyserial and that the bridges import, and starts nothing. From a checkout it behaves as before. The cheap checks (Python, pyserial) now come before starting Docker Desktop, which can take minutes, so a missing Python is reported at once.
packaging/make_bundles.py builds two reproducible zips (the same inputs give the same bytes): - Windows: the launcher scripts, the host-side bridges and the modules they import, an embedded Python with pyserial, and compose.release.yaml, which is the wslg-arm service from compose.yaml run from the tested image pinned by digest. Docker Desktop is the only prerequisite. The bundle fails to build if a bridge imports anything it does not carry, or if the image is not pinned by digest. - macOS: the source at the tag, with Install WayBionic.command, which keeps a copy in ~/WayBionic and installs the app, and the version stamped in the app. The embedded Python and pyserial are pinned by hash: the Python zip is the one python.org signs with Sigstore as hugo@python.org (verified when the pin was made), and pyserial is installed with --require-hashes. The tests cover the compose file, the pin, the bridge imports, the bundle contents (ASCII PowerShell, CRLF text, the _pth file), reproducibility and the macOS stamping.
Pushing a tag vX.Y.Z builds the bundles, checks them on Windows and macOS runners, writes SHA256SUMS, attests where the files came from, tags the image and drafts a GitHub Release. A lead publishes the draft; nothing is public before that. The release is only of a commit on main that has an image CI already tested: the workflow re-tags that image by digest instead of rebuilding it, pins the Windows bundle to the digest, and never moves a version tag that exists. Pull requests that touch the packaging, and manual runs, build and test the same bundles without publishing anything. Actions are pinned by commit.
README: a "Run the real arm" section that leads with the release bundles for Windows and macOS, ahead of the developer quick start. docs/RELEASING.md: the one-time setup (a public image, restricting who can tag), cutting a release with a dry run and a checklist, what the workflow guarantees, undoing a bad release, and updating the pinned Python, pyserial and actions. docs/handover.md: what has been shown to work and how, what has not (the motion modes, the CAD joint limits and the E-stop on the real arm), the known problems, what to check before relying on each, the hardware facts that cost time to find, and the code conventions CI enforces.
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the
|
There was a problem hiding this comment.
🟡 Changes recommended
Critical release workflow defects can prevent draft release creation and allow existing immutable image versions to be overwritten when registry lookups fail.
3 open issues
What changed in this PR
Packages the existing ground-station launchers into Windows and macOS release bundles and adds a workflow for validating them and drafting releases.
Changes:
- Adds reproducible bundles with embedded Python and a digest-pinned image on Windows, and a source installer on macOS.
- Adds platform checks, checksums, build attestations, and a tag-driven release workflow.
- Documents installation and release procedures, and registers bundle and Mac app tests with colcon.
| File | Description |
|---|---|
waybionic_bringup/test/test_release_bundles.py |
Tests bundle contents, image pins, and reproducibility. |
waybionic_bringup/package.xml |
Adds the YAML test dependency. |
waybionic_bringup/CMakeLists.txt |
Registers Mac app and bundle tests. |
scripts/windows-arm.ps1 |
Supports bundled Python, pinned images, and self-tests. |
README.md |
Adds release-download and real-arm startup instructions. |
packaging/windows/Start WayBionic Arm.cmd |
Adds the double-click arm launcher. |
packaging/windows/requirements.txt |
Pins pyserial with a hash. |
packaging/windows/README.txt |
Documents Windows bundle setup and troubleshooting. |
packaging/windows/python-embed.json |
Records embedded Python pins and verification metadata. |
packaging/windows/Check WayBionic Setup.cmd |
Adds the double-click prerequisite check. |
packaging/make_bundles.py |
Builds reproducible Windows and macOS archives. |
packaging/macos/README.txt |
Documents Mac bundle installation and use. |
packaging/macos/Install WayBionic.command |
Copies the source into place and installs the app. |
docs/RELEASING.md |
Documents release setup, publishing, and recovery. |
docs/handover.md |
Records validation status, known gaps, and follow-up checks. |
.github/workflows/release.yml |
Builds and checks bundles, attests assets, and drafts releases. |
Review effort: Balanced
| existing=$(docker buildx imagetools inspect "$IMAGE:v$VERSION" \ | ||
| --format '{{json .Manifest.Digest}}' 2>/dev/null | tr -d '"' || true) |
| gh release create "$GITHUB_REF_NAME" dist/*.zip dist/SHA256SUMS \ | ||
| --title "WayBionic Ground Station $VERSION" "${flags[@]}" |
|
|
||
| What you need | ||
| - An Apple Silicon Mac on macOS 13 or newer. Intel Macs are untested. | ||
| - About 10 GB of free disk space and an internet connection for the first start. |
Making the image public turned out to need more than the package page: its
Public option is greyed out ("Setting is disabled by organization
administrators") until the organisation's Packages policy allows public
packages. RELEASING.md did not say so, so whoever recreated the package would
have been stuck. It now gives the steps in order, including switching the
policy off again afterwards, and a check that needs no login.
It also says that the image is public and that the "Protect release tags"
ruleset exists (both done on 14 November 2026), and handover.md lists the
repository settings changed at the handover, so the new leads know what state
the repository is in.
b99a410 to
bd863c4
Compare
224a119 to
899863b
Compare


Packages the ground station so a Windows or Mac user can start the arm by double-clicking, and gives the software leads a safe way to publish it. Stacked on #59 (and so #57), which hold the launchers it packages; when they merge with a merge commit and their branches are deleted, GitHub retargets this to
main.What it adds
waybionic-ground-station-windows-<version>.zip): the launcher scripts, the host-side bridges and only the modules they import, an embedded Python with pyserial, andcompose.release.yaml: thewslg-armservice fromcompose.yaml, generated rather than copied so they cannot drift, run from the tested image pinned by digest. Docker Desktop is the only prerequisite (no Python, no build). Double-clickStart WayBionic Arm.cmd;Check WayBionic Setup.cmdchecks the laptop and starts nothing.waybionic-ground-station-macos-<version>.zip): the source at the tag plusInstall WayBionic.command, which copies it to~/WayBionic(the app starts the station from a folder, so it must not live in Downloads) and installs the app. The Mac app runs ROS natively, so the first start still sets up the environment (30 to 60 minutes, once); nothing prebuilt can be shipped.windows-arm.ps1now preferspython\python.exebeside it, runs the pinned image without building, pulls it first (with a message for "unauthorized"), takes-SelfTest, and does the cheap checks before starting Docker Desktop. From a checkout it behaves as before..github/workflows/release.yml: a tagvX.Y.Zbuilds the bundles, checks them on Windows and macOS runners, writesSHA256SUMS, attests where the files came from, tags the image and drafts a GitHub Release. A lead publishes the draft.docs/RELEASING.md(one-time setup, cutting a release, undoing one, updating the pins) anddocs/handover.md(what has been shown to work and how, the known problems, what to check next).test_macos_app.pyis now registered with colcon. It was linted but never run in CI; it passes in the CI image.Why it is safe
mainand must already have an image frommain's CI. The release re-tags that image by digest instead of rebuilding it, the Windows bundle names the digest, and an existing version tag with another digest is an error.hugo@python.org(I verified it withsigstore verify identitywhen making the pin; the steps to repeat it are in RELEASING.md). pyserial is installed with--require-hashes. The Windows runner also checks thatpython.exeis signed by the Python Software Foundation. Actions are pinned by commit.SHA256SUMSand build attestations (gh attestation verify). The zips are reproducible: the same inputs give the same bytes.How it was tested
compose.yaml;docker compose -f compose.release.yaml configaccepts it with the digest pinned and nothing to build; two builds are byte-identical.git archiveand ran its installer in a throwawayHOME: it copied to~/WayBionic/ground-station-<version>, installed the app, stamped the version and pointed the app at the copy.test_release_bundles.py(12 tests) andtest_macos_app.pypass in the CI image;ament_flake8andament_pep257are clean;actionlint(with shellcheck) is clean on both workflows;windows-arm.ps1parses in PowerShell 7.packaging/, so the release workflow's dry run runs on it: the Windows job unpacks the bundle and runs its self-test under Windows PowerShell 5.1, and the macOS job checks the installer and the app. See the checks below.Not tested, and what to do about it
releasejob: the ancestor and image checks, the image tag, attestations and the draft) cannot run without a tag. After this merges, make the first release a candidate, for examplev0.1.0-rc1, so a pre-release draft and an image tag are the only things at stake. RELEASING.md has the steps.waybionic_ground_stationpackage is public: an anonymous client gets a token, pulls the:jazzymanifest (linux/amd64 and linux/arm64) and downloads a layer, so a Windows laptop no longer needsdocker login. That needed the organisation's Package creation > Public policy switched on for a minute, because the package page greys out Public otherwise; it is switched off again, so the organisation policy is unchanged and only this package is public. And a tag ruleset, "Protect release tags", lets only themaintainersteam create, move or deletev*tags ("Protect main" is untouched). RELEASING.md now says all of this, which it did not before.Install WayBionic.commandneeds a right-click, Open on macOS.